.navbar {
  background-color: #001529;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.navbar-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  position: relative;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  text-decoration: none;
  font-size: 18px;
  font-weight: 600;
}

.navbar-brand:hover {
  color: #40a9ff;
}

.brand-icon {
  font-size: 24px;
}

.navbar-menu {
  display: flex;
  align-items: center;
  gap: 32px;
  flex: 1;
  justify-content: space-between;
  margin-left: 48px;
}

.navbar-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.65);
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.nav-link:hover {
  color: white;
  background-color: rgba(255, 255, 255, 0.1);
}

.nav-link.active {
  color: #1890ff;
  background-color: rgba(24, 144, 255, 0.1);
}

.nav-icon {
  font-size: 16px;
}

.navbar-user {
  display: flex;
  align-items: center;
  gap: 16px;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  font-size: 14px;
}

.user-icon {
  font-size: 16px;
}

.username {
  font-weight: 500;
}

.user-role {
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 500;
}

.user-role.admin {
  background-color: #f50;
  color: white;
}

.user-role.user {
  background-color: #52c41a;
  color: white;
}

.user-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-sm {
  padding: 4px 12px;
  font-size: 12px;
}

.navbar-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-around;
  width: 24px;
  height: 24px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
}

.navbar-toggle span {
  width: 100%;
  height: 2px;
  background-color: white;
  transition: all 0.3s ease;
}

/* 移动端样式 */
@media (max-width: 1024px) {
  .navbar-menu {
    margin-left: 24px;
  }
  
  .navbar-nav {
    gap: 4px;
  }
  
  .nav-link {
    padding: 6px 12px;
    font-size: 13px;
  }
  
  .user-actions {
    gap: 6px;
  }
}

@media (max-width: 768px) {
  .navbar-toggle {
    display: flex;
  }
  
  .navbar-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: #001529;
    flex-direction: column;
    padding: 16px;
    gap: 16px;
    margin-left: 0;
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  }
  
  .navbar-menu.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  
  .navbar-nav {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    width: 100%;
  }
  
  .nav-link {
    justify-content: flex-start;
    padding: 12px 16px;
    border-radius: 6px;
  }
  
  .navbar-user {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    width: 100%;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .user-info {
    justify-content: center;
    padding: 8px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
  }
  
  .user-actions {
    justify-content: center;
  }
  
  .user-actions .btn {
    flex: 1;
    max-width: 120px;
  }
}

@media (max-width: 480px) {
  .navbar-brand {
    font-size: 16px;
  }
  
  .brand-icon {
    font-size: 20px;
  }
  
  .user-actions {
    flex-direction: column;
    gap: 8px;
  }
  
  .user-actions .btn {
    max-width: none;
    width: 100%;
  }
}
